package com.cos.lession59.services.impl;

import com.cos.lession59.dao.SysRoleMapper;
import com.cos.lession59.entity.SysRole;
import com.cos.lession59.services.SysRoleServices;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author: COS
 * @time: 2022/3/14 9:49
 * @description:
 */
@Service
public class SysRoleServicesImpl implements SysRoleServices {
    @Autowired
    private SysRoleMapper roleMapper;


    @Override
    public List<SysRole> getSysRoleByUserId(Integer uid) {
        if (uid != null && uid > 0) {
            return roleMapper.getSysRoleByUserId(uid);
        }
        return null;
    }
}
